package com.example.designpattern.behavioral.command.command;

import com.example.designpattern.behavioral.command.component.Door;
import lombok.AllArgsConstructor;
import lombok.Data;

@AllArgsConstructor
@Data
public class DoorOpenCommand implements ICommand {
    private Door door;

    @Override
    public void execute() {
        door.openDoor();
    }

    @Override
    public void undo() {
        door.closeDoor();
    }
}

